package date1128.collection;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.lu.jdog.util.Resource;

public class BeanTest2 {
	private static ApplicationContext applicationContext;
	public static void main(String[] args) {
		String xml = Resource.getAssertPath(BeanTest2.class,"beans2.xml");
		applicationContext = new ClassPathXmlApplicationContext(xml);
		
		Persons2 persons = applicationContext.getBean("persons2",Persons2.class);
		System.out.println(persons.toString());
		
		Persons2 child = applicationContext.getBean("child",Persons2.class);
		System.out.println(child.toString());
	}
}
